package cn.itsource.ymcc.openfeign;

import cn.itsource.ymcc.openfeign.factory.CourseOpenfeignFallbackFactory;
import cn.itsource.ymcc.result.JsonResult;
import cn.itsource.ymcc.vo.CourseUserLearnVo;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;

@FeignClient(value = "service-course",fallbackFactory = CourseOpenfeignFallbackFactory.class)
public interface CourseOpenfeign {
    @GetMapping("/courseMarket/{id}")
    public JsonResult get(@PathVariable("id")Long id);

    @PostMapping("/courseUserLearn/info")
    public JsonResult getUserLearnInfo(@RequestBody CourseUserLearnVo courseUserLearnVo);
}
